<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;


/**
 * App\Models\ShopRecord
 *
 * @property int $id
 * @property int $shop_id 店铺ID
 * @property int $visitors 访问量
 * @property int $orders 订单量
 * @property float $turnovers 营业额
 * @property int $datestamp 日期
 * @property-read \App\Models\Shop $shop
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShopRecord whereDatestamp($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShopRecord whereId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShopRecord whereOrders($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShopRecord whereShopId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShopRecord whereTurnovers($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShopRecord whereVisitors($value)
 * @mixin \Eloquent
 */
class ShopRecord extends Model
{
    protected $table = 'shop_record';
    protected $primaryKey = 'id';
    protected $guarded = ['id'];

    public $timestamps = false;

    public function shop()
    {
        return $this->belongsTo(Shop::class, 'shop_id', 'shop_id');
    }
}
